package com.ant.storage.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * <p>
 * 
 * </p>
 *
 * @author melon
 * @since 2022-03-16
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("purchase_orders")
@ApiModel(value="PurchaseOrders对象", description="")
public class PurchaseOrders implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "采购单号")
    @TableField("orders_number")
    private String ordersNumber;

    @ApiModelProperty(value = "采购单id")
    @TableField("parent_id")
    private Integer parentId;

    @ApiModelProperty(value = "部门id")
    @TableField("department_id")
    private Integer departmentId;

    @ApiModelProperty(value = "供应商id")
    @TableField("supplier_id")
    private Integer supplierId;

    @ApiModelProperty(value = "商品中间表id")
    @TableField("goods_pool_commodity_id")
    private Integer goodsPoolCommodityId;

    @ApiModelProperty(value = "总额")
    @TableField("goods_total_price")
    private BigDecimal goodsTotalPrice;

    @ApiModelProperty(value = "物品采购状态 0 未完成 1 保存中 2 已完成 3 入库 4 取消 5 已退回")
    @TableField("goods_status")
    private Integer goodsStatus;

    @ApiModelProperty(value = "支付方式")
    @TableField("payment_method")
    private Integer paymentMethod;

    @ApiModelProperty(value = "图片")
    @TableField("img")
    private String img;

    @ApiModelProperty(value = "备注")
    @TableField("remark")
    private String remark;

    @ApiModelProperty(value = "仓库id")
    @TableField("warehouse_id")
    private Integer warehouseId;

    @ApiModelProperty(value = "采购人id")
    @TableField("purchaser_id")
    private Integer purchaserId;

    @ApiModelProperty(value = "结算")
    @TableField("is_settlement")
    private Integer isSettlement;

    @ApiModelProperty(value = "采购渠道")
    @TableField("channel")
    private Integer channel;


    @TableField("modifier_by")
    private String modifierBy;

    @TableField("creation_time")
    private Date creationTime;


    @TableField(exist = false)
    private String commodityName;

    @TableField(exist = false)
    private String commodityUnits;


    @TableField(exist = false)
    private Integer commodityAmount;


    @TableField(exist = false)
    private BigDecimal commodityPrice;
}
